package com.kgc.service;

import com.github.pagehelper.PageInfo;
import com.kgc.entity.Category;
import com.kgc.entity.Product;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * @author :qinya
 * @PackageName:com.kgc.service
 * @ClassName: ProductService
 * @Description: TODO
 * @date : 2025/5/16,21:17
 */
public interface ProductService {
    PageInfo<Product> selectByPage(Map<String, Object> params);

    boolean editProduct(Product product);

    boolean addProduct(Product product);

    boolean delProduct(String id);

    Product selectById(String id);

    boolean editProductStock(Product product);

    List<Category> selectCategoryByProduct(@Param("product") Product product);

    //校验预出库
    boolean checkStock(int preOut, String productId);
}
